<?php
/*
 *author:Yangligao
 *Date:2013-9-26
 */

$adminModel = new AdminModel();
$res = $adminModel->admin_select('admin_power',"where admin_id = ".$_SESSION['id']);

if($res[0]['admin_power'] == "111"){
	$isSuper = 1;
}else{
	$isSuper = 0;
}
$smarty->assign('isSuper',$isSuper);

if($res[0]['admin_power'][0] == '1'){
	$isInsert = 1;
}else{
	$isInsert = 0;
}
$smarty->assign('isInsert',$isInsert);

if($res[0]['admin_power'][1] == '1'){
	$isdelete = 1;
}else{
	$isdelete = 0;
}
$smarty->assign('isDelete',$isdelete);
if($res[0]['admin_power'][2] == '1'){
	$isupdate = 1;
}else{
	$isupdate = 0;
}
$smarty->assign('isUpdate',$isupdate);
?>
